﻿function A(lat, lng) {
    this._lat = lat;
    this._lng = lng;
}
A.prototype = new BMap.Overlay();
A.prototype.initialize = function(map) {
    this._map = map;
    var tb = document.createElement("table");
	tb.cellPadding=0;
	tb.cellSpacing=0;
	tb.appendChild(this.createrow("山东",0));
	tb.appendChild(this.createrow("",1));
    map.getPanes().markerPane.appendChild(table);
    this.tb = tb;
    return tb;
}
A.prototype.createrow=function(v,t)
{
	var row=document.createElement("row");
	var td=document.createElement("td");
	if(t==0)
	{
	td.className="l";
	row.appendChild(td);
	td.className="m";
	td.innerHTML=v;
	row.appendChild(td);
	td.className="r";
	td.innerHTML="";
	row.appendChild(td);
	}
	else
	{
	row.className="b";
	td.setAttribute("colspan","3");
	row.appendChild(td);
	}
	return row;
}
A.prototype.draw = function() { 
 var position = this._map.pointToOverlayPixel(this._center);   
this.tb.style.left = position.x - this._length / 2 + "px";   
this.tb.style.top = position.y - this._length / 2 + "px";
}